<?php
$tdatasize_systems=array();
	$tdatasize_systems[".NumberOfChars"]=80; 
	$tdatasize_systems[".ShortName"]="size_systems";
	$tdatasize_systems[".OwnerID"]="";
	$tdatasize_systems[".OriginalTable"]="size_systems";


	
//	field labels
$fieldLabelssize_systems = array();
if(mlang_getcurrentlang()=="English")
{
	$fieldLabelssize_systems["English"]=array();
	$fieldToolTipssize_systems["English"]=array();
	$fieldLabelssize_systems["English"]["id"] = "Id";
	$fieldToolTipssize_systems["English"]["id"] = "";
	$fieldLabelssize_systems["English"]["size_system_name"] = "Size System Name";
	$fieldToolTipssize_systems["English"]["size_system_name"] = "";
	if (count($fieldToolTipssize_systems["English"])){
		$tdatasize_systems[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="Chinese (Hong Kong S.A.R.)")
{
	$fieldLabelssize_systems["Chinese (Hong Kong S.A.R.)"]=array();
	$fieldToolTipssize_systems["Chinese (Hong Kong S.A.R.)"]=array();
	$fieldLabelssize_systems["Chinese (Hong Kong S.A.R.)"]["id"] = "Id";
	$fieldToolTipssize_systems["Chinese (Hong Kong S.A.R.)"]["id"] = "";
	$fieldLabelssize_systems["Chinese (Hong Kong S.A.R.)"]["size_system_name"] = "Size System Name";
	$fieldToolTipssize_systems["Chinese (Hong Kong S.A.R.)"]["size_system_name"] = "";
	if (count($fieldToolTipssize_systems["Chinese (Hong Kong S.A.R.)"])){
		$tdatasize_systems[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="Chinese (Taiwan)")
{
	$fieldLabelssize_systems["Chinese (Taiwan)"]=array();
	$fieldToolTipssize_systems["Chinese (Taiwan)"]=array();
	$fieldLabelssize_systems["Chinese (Taiwan)"]["id"] = "Id";
	$fieldToolTipssize_systems["Chinese (Taiwan)"]["id"] = "";
	$fieldLabelssize_systems["Chinese (Taiwan)"]["size_system_name"] = "Size System Name";
	$fieldToolTipssize_systems["Chinese (Taiwan)"]["size_system_name"] = "";
	if (count($fieldToolTipssize_systems["Chinese (Taiwan)"])){
		$tdatasize_systems[".isUseToolTips"]=true;
	}
}
if(mlang_getcurrentlang()=="French")
{
	$fieldLabelssize_systems["French"]=array();
	$fieldToolTipssize_systems["French"]=array();
	if (count($fieldToolTipssize_systems["French"])){
		$tdatasize_systems[".isUseToolTips"]=true;
	}
}


	
	$tdatasize_systems[".NCSearch"]=true;

	

$tdatasize_systems[".shortTableName"] = "size_systems";
$tdatasize_systems[".nSecOptions"] = 0;
$tdatasize_systems[".recsPerRowList"] = 1;	
$tdatasize_systems[".tableGroupBy"] = "0";
$tdatasize_systems[".mainTableOwnerID"] = "";
$tdatasize_systems[".moveNext"] = 1;




$tdatasize_systems[".showAddInPopup"] = false;

$tdatasize_systems[".showEditInPopup"] = false;

$tdatasize_systems[".showViewInPopup"] = false;


$tdatasize_systems[".fieldsForRegister"] = array();

$tdatasize_systems[".listAjax"] = true;

	$tdatasize_systems[".audit"] = false;

	$tdatasize_systems[".locking"] = false;
	
$tdatasize_systems[".listIcons"] = true;
$tdatasize_systems[".edit"] = true;
$tdatasize_systems[".inlineEdit"] = true;
$tdatasize_systems[".view"] = true;

$tdatasize_systems[".exportTo"] = true;

$tdatasize_systems[".printFriendly"] = true;

$tdatasize_systems[".delete"] = true;

$tdatasize_systems[".showSimpleSearchOptions"] = true;

$tdatasize_systems[".showSearchPanel"] = true;


$tdatasize_systems[".isUseAjaxSuggest"] = true;

$tdatasize_systems[".rowHighlite"] = true;


// button handlers file names

$tdatasize_systems[".addPageEvents"] = false;

$tdatasize_systems[".arrKeyFields"][] = "id";

// use datepicker for search panel
$tdatasize_systems[".isUseCalendarForSearch"] = false;

// use timepicker for search panel
$tdatasize_systems[".isUseTimeForSearch"] = false;

$tdatasize_systems[".isUseiBox"] = false;


$tdatasize_systems[".useDetailsPreview"] = true;	

$tdatasize_systems[".isUseInlineAdd"] = true;

$tdatasize_systems[".isUseInlineEdit"] = true;
$tdatasize_systems[".isUseInlineJs"] = $tdatasize_systems[".isUseInlineAdd"] || $tdatasize_systems[".isUseInlineEdit"];

$tdatasize_systems[".allSearchFields"] = array();

$tdatasize_systems[".globSearchFields"][] = "id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("id", $tdatasize_systems[".allSearchFields"]))
{
	$tdatasize_systems[".allSearchFields"][] = "id";	
}
$tdatasize_systems[".globSearchFields"][] = "size_system_name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("size_system_name", $tdatasize_systems[".allSearchFields"]))
{
	$tdatasize_systems[".allSearchFields"][] = "size_system_name";	
}


$tdatasize_systems[".googleLikeFields"][] = "id";
$tdatasize_systems[".googleLikeFields"][] = "size_system_name";



$tdatasize_systems[".advSearchFields"][] = "id";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("id", $tdatasize_systems[".allSearchFields"])) 
{
	$tdatasize_systems[".allSearchFields"][] = "id";	
}
$tdatasize_systems[".advSearchFields"][] = "size_system_name";
// do in this way, because combine functions array_unique and array_merge returns array with keys like 1,2, 4 etc
if (!in_array("size_system_name", $tdatasize_systems[".allSearchFields"])) 
{
	$tdatasize_systems[".allSearchFields"][] = "size_system_name";	
}

$tdatasize_systems[".isTableType"] = "list";


	

$tdatasize_systems[".isDisplayLoading"] = true;

$tdatasize_systems[".isResizeColumns"] = false;

	$tdatasize_systems[".subQueriesSupAccess"] = true;




$tdatasize_systems[".pageSize"] = 20;

$gstrOrderBy = "";
if(strlen($gstrOrderBy) && strtolower(substr($gstrOrderBy,0,8))!="order by")
	$gstrOrderBy = "order by ".$gstrOrderBy;
$tdatasize_systems[".strOrderBy"] = $gstrOrderBy;
	
$tdatasize_systems[".orderindexes"] = array();

$tdatasize_systems[".sqlHead"] = "SELECT id,   size_system_name";
$tdatasize_systems[".sqlFrom"] = "FROM size_systems";
$tdatasize_systems[".sqlWhereExpr"] = "";
$tdatasize_systems[".sqlTail"] = "";




//fill array of records per page for list and report without group fields
$arrRPP = array();
$arrRPP[] = 10;
$arrRPP[] = 20;
$arrRPP[] = 30;
$arrRPP[] = 50;
$arrRPP[] = 100;
$arrRPP[] = 500;
$arrRPP[] = -1;
$tdatasize_systems[".arrRecsPerPage"] = $arrRPP;

//fill array of groups per page for report with group fields
$arrGPP = array();
$arrGPP[] = 1;
$arrGPP[] = 3;
$arrGPP[] = 5;
$arrGPP[] = 10;
$arrGPP[] = 50;
$arrGPP[] = 100;
$arrGPP[] = -1;
$tdatasize_systems[".arrGroupsPerPage"] = $arrGPP;

	$tableKeys = array();
	$tableKeys[] = "id";
	$tdatasize_systems[".Keys"] = $tableKeys;

//	id
	$fdata = array();
	$fdata["strName"] = "id";
	$fdata["ownerTable"] = "size_systems";
		$fdata["Label"]="Id"; 
	
		
		
	$fdata["FieldType"]= 3;
	
		$fdata["AutoInc"]=true;
	
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "id";
	
		$fdata["FullName"]= "id";
	
		$fdata["IsRequired"]=true; 
	
		
		
		
		
				$fdata["Index"]= 1;
				$fdata["EditParams"]="";
			
		$fdata["bListPage"]=true; 
	
		
		
		
		
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
				$fdata["validateAs"]["basicValidate"][] = getJsValidatorName("Number");	
						$fdata["validateAs"]["basicValidate"][] = "IsRequired";
	
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatasize_systems["id"]=$fdata;
//	size_system_name
	$fdata = array();
	$fdata["strName"] = "size_system_name";
	$fdata["ownerTable"] = "size_systems";
		$fdata["Label"]="Size System Name"; 
	
		
		
	$fdata["FieldType"]= 200;
	
		
			$fdata["UseiBox"] = false;
	
	$fdata["EditFormat"]= "Text field";
	$fdata["ViewFormat"]= "";
	
		
		
		
		
		$fdata["NeedEncode"]=true;
	
	$fdata["GoodName"]= "size_system_name";
	
		$fdata["FullName"]= "size_system_name";
	
		
		
		
		
		
				$fdata["Index"]= 2;
				$fdata["EditParams"]="";
			$fdata["EditParams"].= " maxlength=255";
		
		$fdata["bListPage"]=true; 
	
		$fdata["bAddPage"]=true; 
	
		$fdata["bInlineAdd"]=true; 
	
		$fdata["bEditPage"]=true; 
	
		$fdata["bInlineEdit"]=true; 
	
		$fdata["bViewPage"]=true; 
	
		$fdata["bAdvancedSearch"]=true; 
	
		$fdata["bPrinterPage"]=true; 
	
		$fdata["bExportPage"]=true; 
	
	//Begin validation
	$fdata["validateAs"] = array();
		
		//End validation
	
				$fdata["FieldPermissions"]=true;
	
		
				
		
		
		
			$tdatasize_systems["size_system_name"]=$fdata;

	
$tables_data["size_systems"]=&$tdatasize_systems;
$field_labels["size_systems"] = &$fieldLabelssize_systems;
$fieldToolTips["size_systems"] = &$fieldToolTipssize_systems;

// -----------------start  prepare master-details data arrays ------------------------------//
// tables which are detail tables for current table (master)
$detailsTablesData["size_systems"] = array();
$dIndex = 1-1;
			$strOriginalDetailsTable="sales_order_items";
	$detailsTablesData["size_systems"][$dIndex] = array(
		  "dDataSourceTable"=>"sales_order_items"
		, "dOriginalTable"=>$strOriginalDetailsTable
		, "dShortTable"=>"sales_order_items"
		, "masterKeys"=>array()
		, "detailKeys"=>array()
		, "dispChildCount"=> "1"
		, "hideChild"=>"1"
		, "sqlHead"=>"SELECT id,   sales_order_id,   item_no,   product_id,   property_id,   size_system_id,   unit_price,   total_quantity,   size_breakup_id,   delivery_date,   status"	
		, "sqlFrom"=>"FROM sales_order_items"	
		, "sqlWhere"=>""
		, "sqlTail"=>""
		, "groupBy"=>"0"
		, "previewOnList" => 1
		, "previewOnAdd" => 1
		, "previewOnEdit" => 1
		, "previewOnView" => 1
	);	
		$detailsTablesData["size_systems"][$dIndex]["masterKeys"][]="id";
		$detailsTablesData["size_systems"][$dIndex]["detailKeys"][]="size_system_id";

$dIndex = 2-1;
			$strOriginalDetailsTable="size_breakup";
	$detailsTablesData["size_systems"][$dIndex] = array(
		  "dDataSourceTable"=>"size_breakup"
		, "dOriginalTable"=>$strOriginalDetailsTable
		, "dShortTable"=>"size_breakup"
		, "masterKeys"=>array()
		, "detailKeys"=>array()
		, "dispChildCount"=> "1"
		, "hideChild"=>"1"
		, "sqlHead"=>"SELECT id,   size_code,   size_system_id"	
		, "sqlFrom"=>"FROM size_breakup"	
		, "sqlWhere"=>""
		, "sqlTail"=>""
		, "groupBy"=>"0"
		, "previewOnList" => 1
		, "previewOnAdd" => 1
		, "previewOnEdit" => 1
		, "previewOnView" => 1
	);	
		$detailsTablesData["size_systems"][$dIndex]["masterKeys"][]="id";
		$detailsTablesData["size_systems"][$dIndex]["detailKeys"][]="size_system_id";


	
// tables which are master tables for current table (detail)
$masterTablesData["size_systems"] = array();

// -----------------end  prepare master-details data arrays ------------------------------//

require_once(getabspath("classes/sql.php"));










$proto314=array();
$proto314["m_strHead"] = "SELECT";
$proto314["m_strFieldList"] = "id,   size_system_name";
$proto314["m_strFrom"] = "FROM size_systems";
$proto314["m_strWhere"] = "";
$proto314["m_strOrderBy"] = "";
$proto314["m_strTail"] = "";
$proto315=array();
$proto315["m_sql"] = "";
$proto315["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto315["m_column"]=$obj;
$proto315["m_contained"] = array();
$proto315["m_strCase"] = "";
$proto315["m_havingmode"] = "0";
$proto315["m_inBrackets"] = "0";
$proto315["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto315);

$proto314["m_where"] = $obj;
$proto317=array();
$proto317["m_sql"] = "";
$proto317["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto317["m_column"]=$obj;
$proto317["m_contained"] = array();
$proto317["m_strCase"] = "";
$proto317["m_havingmode"] = "0";
$proto317["m_inBrackets"] = "0";
$proto317["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto317);

$proto314["m_having"] = $obj;
$proto314["m_fieldlist"] = array();
						$proto319=array();
			$obj = new SQLField(array(
	"m_strName" => "id",
	"m_strTable" => "size_systems"
));

$proto319["m_expr"]=$obj;
$proto319["m_alias"] = "";
$obj = new SQLFieldListItem($proto319);

$proto314["m_fieldlist"][]=$obj;
						$proto321=array();
			$obj = new SQLField(array(
	"m_strName" => "size_system_name",
	"m_strTable" => "size_systems"
));

$proto321["m_expr"]=$obj;
$proto321["m_alias"] = "";
$obj = new SQLFieldListItem($proto321);

$proto314["m_fieldlist"][]=$obj;
$proto314["m_fromlist"] = array();
												$proto323=array();
$proto323["m_link"] = "SQLL_MAIN";
			$proto324=array();
$proto324["m_strName"] = "size_systems";
$proto324["m_columns"] = array();
$proto324["m_columns"][] = "id";
$proto324["m_columns"][] = "size_system_name";
$obj = new SQLTable($proto324);

$proto323["m_table"] = $obj;
$proto323["m_alias"] = "";
$proto325=array();
$proto325["m_sql"] = "";
$proto325["m_uniontype"] = "SQLL_UNKNOWN";
	$obj = new SQLNonParsed(array(
	"m_sql" => ""
));

$proto325["m_column"]=$obj;
$proto325["m_contained"] = array();
$proto325["m_strCase"] = "";
$proto325["m_havingmode"] = "0";
$proto325["m_inBrackets"] = "0";
$proto325["m_useAlias"] = "0";
$obj = new SQLLogicalExpr($proto325);

$proto323["m_joinon"] = $obj;
$obj = new SQLFromListItem($proto323);

$proto314["m_fromlist"][]=$obj;
$proto314["m_groupby"] = array();
$proto314["m_orderby"] = array();
$obj = new SQLQuery($proto314);

$queryData_size_systems = $obj;
$tdatasize_systems[".sqlquery"] = $queryData_size_systems;

$tableEvents["size_systems"] = new eventsBase;

?>
